package com.oocl.chatroom.network.protocol;

import java.io.Serializable;

public class Message implements Serializable{

	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;
	
	private String content;
	private int Type;   // chat,shake,online,downline,notifylist,register,login     0,1,2,3,4,5,6
	private String sender;
	private String receiver;
	private long date;
	
	public long getDate() {
		return date;
	}

	public void setDate(long date) {
		this.date = date;
	}

	public int getType() {
		return Type;
	}

	public String getContent() {
		return content;
	}

	public void setContent(String content) {
		this.content = content;
	}

	public void setType(int type) {
		Type = type;
	}

	public String getSender() {
		return sender;
	}

	public void setSender(String sender) {
		this.sender = sender;
	}

	public String getReceiver() {
		return receiver;
	}

	public void setReceiver(String receiver) {
		this.receiver = receiver;
	}

	public Message() {
	}

	public Message(String content, int type, String sender, String receiver,
			long date) {
		super();
		this.content = content;
		Type = type;
		this.sender = sender;
		this.receiver = receiver;
		this.date = date;
	}

	@Override
	public String toString() {
		return "Message [content=" + content + ", Type=" + Type + ", sender="
				+ sender + ", receiver=" + receiver + ", date=" + date + "]";
	}
	
}
